home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Precision Software Appli…tions Silver Collection 1
/
Precision Software Applications Silver Collection Volume One (PSM) (1993).iso
/
tutor
/
dosguide.exe
/
HELPDOS.ZIP
/
FOR.HLP
< prev
next >
Wrap
Text File
|
1985-09-03
|
908b
|
24 lines
---------------------- FOR - Internal Batch Subcommand -----------------------
FOR allows you to execute the same DOS command for each of a group of files.
FORMAT: FOR %%variable IN (set) DO command
REMARKS:
%%variable - sequentially assigned to each file in "set" to allow "command"
to be performed for each file. "Variable" must be a single
letter.
set - is one or more file specifications of the form d:filename.ext.
Global characters (* and ?) are allowed. Path names are not
allowed.
command - the DOS command to be performed for each file in "set." The
command cannot be another FOR Subcommand.
EXAMPLE:
The following batch file displays (via the TYPE command) the contents of the
files FILE1, FILE2 and FILE3:
FOR %%f IN (file1 file2 file3) DO TYPE %%f